package main

import "fmt"

func main() {
	ch := make(chan int, 1)
	ch <- 10
	x, ok := <-ch
	fmt.Println(x, ok)
	ch <- 20
	y, ok2 := <-ch
	fmt.Println(y, ok2)
	close(ch)
}
